From e00465ab66d4d59d1e33835c9d2737edb49d019a Mon Sep 17 00:00:00 2001 From: Tim Starling Date: Thu, 20 Jan 2011 05:18:39 +0000 Subject: [PATCH] In getCategorySortkey: strip tabs and line feeds from the user-supplied category sort key, to avoid conflicts with our usage of LF. In UCA, tab is the only character that can sort above LF. --- includes/Title.php | 1 + 1 file changed, 1 insertion(+) diff --git a/includes/Title.php b/includes/Title.php index fd62d4dcc1..c8fe7b8d27 100644 --- a/includes/Title.php +++ b/includes/Title.php @@ -4152,6 +4152,7 @@ class Title { # Separate with a null byte, so the unprefixed part is only used as # a tiebreaker when two pages have the exact same prefix -- null # sorts before everything else (hopefully). + $prefix = strtr( $prefix, "\n\t", ' ' ); return "$prefix\n$unprefixed"; } return $unprefixed; -- 2.20.1